package com.ichart.doc;

import java.util.HashMap;
import java.util.Map;

public class Info{
	public static String VERSION = "1.2"; 
	public static String SUFFIX = ".html";
	private static int LANGUAGE = 0;
	public static int ENGLISH = 0;
	public static int CHINESE = 1;
	public static String HomeSite = "http://www.ichartjs.com";
	public static String SitePath = "E:/workspace8.6/ichartjsHome/";
	public static String TargetPath = "E:/workspace8.6/ichartjs/";
	public static String DOCUMENT = TargetPath + "docs/en/";
	public static String PluginPath = "E:/workspace8.6/ichartjs/plugin/";
	public static String SrcPath = "E:/workspace8.6/ichartjs/src/";
	public static String MinifyPath = TargetPath + "minify/";
	
	private static Map<String,String> map = new HashMap<String,String>();
	
	public static void setSrcPath(String path){
		SrcPath = path;
	}
	public static void setTargetPath(String path){
		TargetPath = path;
		MinifyPath = TargetPath + "minify/";
	}
	
	public static void setLanguage(int l){
		DOCUMENT = new String[]{TargetPath + "docs/en/",TargetPath + "docs/zh/"}[Info.LANGUAGE = l%2];
	}
	
	static{
		map.put("Hierarchy","层次树");
		map.put("Charts","图表类");
		map.put("Overview","概览");
		map.put("Configs","配置项");
		map.put("Events","事件");
		map.put("Parameter","参数");
		map.put("Name","名称");
		map.put("Type","类型");
		map.put("Description","描述");
		map.put("Defined By","定义者");
		map.put("reference","参考");
		map.put("Home","主页");
		map.put("Methods","方法");
		map.put("None","无");
		map.put("Return","返回值");
		map.put("AllClass","全部类");
	}
	
	public static String info(String key){
		if(Info.LANGUAGE==ENGLISH){
			return key;
		}else{
			return map.get(key);
		}
	}
	
	
	
	
}
